﻿@*@model MobileWebsiteGenerator.Entities.Customer
@{
    ViewBag.Title = "Edit";
}
<h2>
    Edit</h2>
<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>
@using (Html.BeginForm())
{
    @Html.ValidationSummary(true)
    <fieldset>
        <legend>Customer</legend>
        @Html.HiddenFor(model => model.Customer_id)
        <div class="editor-label">
            @Html.LabelFor(model => model.UserName)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.UserName)
            @Html.ValidationMessageFor(model => model.UserName)
        </div>
        <div class="editor-label">
            @Html.LabelFor(model => model.FullName)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.FullName)
            @Html.ValidationMessageFor(model => model.FullName)
        </div>
        <div class="editor-label">
            @Html.LabelFor(model => model.company)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.company)
            @Html.ValidationMessageFor(model => model.company)
        </div>
        <div class="editor-label">
            @Html.LabelFor(model => model.WebsiteAddress)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.WebsiteAddress)
            @Html.ValidationMessageFor(model => model.WebsiteAddress)
        </div>
        <div class="editor-label">
            @Html.LabelFor(model => model.Email)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Email)
            @Html.ValidationMessageFor(model => model.Email)
        </div>
        <div class="editor-label">
            @Html.LabelFor(model => model.phone)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.phone)
            @Html.ValidationMessageFor(model => model.phone)
        </div>
        <p>
            <input type="submit" value="Save" />
        </p>
    </fieldset>
}
<div>
    @Html.ActionLink("Back to List", "Index")
</div>
*@
@model MobileWebsiteGenerator.Entities.Customer
@{
    Layout = "~/Views/Shared/_Layout_Login.cshtml";
}
<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Content/Forms/En%20engine.js")" type="text/javascript"></script>
<link href="@Url.Content("~/Content/Forms/Engine.css")" rel="stylesheet" type="text/css" />
<script src="@Url.Content("~/Content/Forms/Engine.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Content/js/jquery.maskedinput-1.3.js")" type="text/javascript"></script>
<div style="float: right; margin-left: 200px; vertical-align: top; margin: 0px; padding: 0px;"
    class="form_content">
    <h3>
        Edit Personal Details
    </h3>
    <div>
        <form id="pform" class="" method="post" action="/Customer/Edit">
        @Html.HiddenFor(model => model.Customer_id)
        <div class="form_row">
            <label>
                Full Name</label>
            <input class="form_input validate[required,minSize[5]] text-input" id="FullName"
                name="FullName" type="text" value="@Model.FullName" />
            <span class="field-validation-valid" data-valmsg-for="FullName" data-valmsg-replace="true">
            </span>
        </div>
    
        @Html.HiddenFor(model => model.IsActive)
        @Html.HiddenFor(model => model.web_id)
        <div style="float:right;"  class="form_row">
            <label>
                Username</label>
            <input class="form_input validate[required,minSize[5],custom[onlyLetterNumber]] text-input "
                id="UserName" name="UserName" type="text" value="@Model.UserName" />
            <span class="field-validation-valid" data-valmsg-for="UserName" data-valmsg-replace="true">
            </span>
        </div>
        <div class="form_row">
            <label>
                Password</label>
            <input class="form_input validate[required,minSize[5],custom[onlyLetterNumber]] text-input "
                id="Password" name="Password" type="password" value="@Model.Password"/>
            <span class="field-validation-valid" data-valmsg-for="UserName" data-valmsg-replace="true">
            </span>
        </div>

         <div class="form_row">
            <label>
                Confirm Password</label>
            <input class="form_input validate[required] text-input" id="confirmPassword" name="confirmPassword"
                type="password" value="@Model.confirmPassword" />
            <span class="field-validation-valid" data-valmsg-for="confirmPassword" data-valmsg-replace="true">
            </span>
        </div>



        <div class="form_row">
            <label>
                Email</label>
            <input class="form_input validate[required,custom[email]] text-input" data-val="true"
                data-val-required="The Email field is required." id="Email" name="Email" type="text"
                value="@Model.Email" />
        </div>

          <div class="form_row">
            <label>
                Confirm Email</label>
            <input class="form_input validate[required,custom[email]] text-input" id="ConfirmEmail"
                name="ConfirmEmail" type="text" value="@Model.ConfirmEmail" />
            <span class="field-validation-valid" data-valmsg-for="ConfirmEmail" data-valmsg-replace="true">
            </span>
        </div>

        <div class="form_row">
            <label>
                Company</label>
            <input class="form_input " id="company" name="company" type="text" value="@Model.company" />
            <span class="field-validation-valid" data-valmsg-for="company" data-valmsg-replace="true">
            </span>
        </div>
        <div class="form_row">
            <label>
                Website</label>
            <input class="form_input  " id="WebsiteAddress" name="WebsiteAddress" type="text"
                value="@Model.WebsiteAddress" />
            <span class=" field-validation-valid" data-valmsg-for="WebsiteAddress" data-valmsg-replace="true">
            </span>
        </div>
        <div class="form_row">
            <label>
                Phone</label>
            <input type="text" class="form_input  " name="phone" id="phone" value="@Model.phone" />
        </div>
        <input type="Submit" class="form_submit" name="submit" value="Update" />
        </form>
    </div>
</div>
<style type="text/css">
    #submit:hover
    {
        background-color: #11639d;
        color: White;
    }
    
    div.form_content .form_row label
    {
        background-color: #11639d;
        color: White;
    }
</style>
